<?php

namespace loggedin\view;

class MemberAreaView {
	private static $sessionLoggedIn = "loggedin";
	private static $getLogout = "logout";

	/**
	 * @return string HTML
	 */
	public function getMemberStartPage() {
		return "<!DOCTYPE HTML SYSTEM>
		<html>
			<head>
				<title>Quizzer inloggad</title>
				<meta charset='UTF-8'>
			</head>
			<body>
				<div class='wrapper'>
					<div class='leftBox'>
						<h1>Quizzer</h1>
						<a href='?logout'>Logga ut</a><br/>
						<a href='?startgame'>Starta nytt spel</a><br/>
						<a href='?addquestion'>Lägg till egen fråga</a><br/>
						<a href='?myquestions'>Mina egna frågor</a><br/>
					</div>

					<div class='mainContent'>
						<br>
					</div>
				</div>
			</body>
		</html>";
	}

	/**
	 * @return boolean
	 */
	public function getLogoutInfo() {
		return isset($_GET[self::$getLogout]) && isset($_SESSION[self::$sessionLoggedIn]);
	}
}